package com.whfc.common.enums;

/**
 * @Description: 在岗状态
 * @author: xugcheng
 * @version: 1.0
 * @date: 2019/7/29 11:37
 */
public enum PostState {

    ENTER(1, "在职"),

    OUTER(2, "离职");

    private Integer value;

    private String desc;

    PostState(Integer value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    public Integer getValue() {
        return value;
    }

    public String getDesc() {
        return desc;
    }

    public static PostState parseValue(Integer value) {
        switch (value) {
            case 1:
                return ENTER;
            case 2:
                return OUTER;
            default:
                return ENTER;
        }
    }
}
